module.exports = (req, res, next) => {
    // 如果用户登录成功，那么肯定携带session
    if(req.session.logined &&  req.session.uname){
        return next()
    } else {
        res.redirect("http://localhost:3000/")
    }
}